<!DOCTYPE html>
<html lang="en">
<head>
    <include file="Public:header2" />
    <script type="text/javascript" src="__PUBLIC__/layer/layer.js"></script>
    <script type="text/javascript" src="__PUBLIC__/Home/js/jquery.cookies.2.2.0.js"></script>
</head>
<body class="blackbg">
    <div id="container" class="logbg">
        <div class="log_title">
            <span class="back"><a href="javascript:history.go(-1)"></a></span>
            {:L('提现记录')}
        </div>
        <span class="addbankbut">
            <a href="{:U('Finance/mytx')}">{:L('人民币提现')}</a>
        </span>
        <div class="chgbox">
            <ul>


            <empty name="list">
                <li>
                    <div class="chglist_top" style="text-align: center;">
                        <span class="state wait" style="float: none;color:#B7B6B6">
                            {:L('暂无提现记录')}
                        </span>
                    </div>
                </li>
            <else />

                <volist name="list" id="vo">
                    <li>
                        <div class="withdrawtop on">
                            {$vo.addtime|date='Y-m-d H:i:s',###}
                            <span class="state wait" style="float: right;">
                                <eq name="vo.status" value="0">
                                    {:L('已申请')}
                                    <a onclick="mytxChexiao({$vo['id']})" href="javascript:void(0)" style="color: #ff9900!important;">{:L('撤销')}</a>
                                </eq>
                                <eq name="vo.status" value="1">
                                    {:L('提现成功')}
                                </eq>
                                <eq name="vo.status" value="2">
                                    {:L('已撤销')}
                                </eq>
                                <eq name="vo.status" value="3">
                                    {:L('正在处理')}
                                </eq></span>
                        </div>
                        <table class="withdrawtable nobotcolor">
                            <tr>
                                <th>
                                    <p>{:L('提现金额')}</p>
                                    <b>${$vo['num']|default="0.00"}</b>
                                </th>
                                <th>
                                    <p>{:L('手续费')}</p>
                                    <b>{$vo['fee']|default="0.00"}</b>
                                </th>
                                <th>
                                    <p>{:L('到账金额')}</p>
                                    <b>${$vo['mum']|default="0.00"}</b>
                                </th>
                            </tr>
                        </table>
                        <table class="withdrawtable bottable">
                            <tr>
                                <td colspan="3" style="padding-top:10px;">{:L('持卡人')}：{$vo['truename']}</td>
                            </tr>
                            <tr>
                                <td colspan="3">{:L('提现银行')}：{$vo['bank']}</td>
                            </tr>
                            <tr>
                                <td colspan="3" style="padding-bottom: 10px;">{:L('提现卡号')}：{$vo['bankcard']}</td>
                            </tr>
                            <!-- <tr>
                                <th>提现银行</th>
                                <th>提现卡号</th>
                                <th>持卡人</th>
                            </tr>
                            <tr>
                                <td>{$vo['bank']}</td>
                                <td>{$vo['bankcard']}</td>
                                <td>{$vo['truename']}</td>
                            </tr> -->
                            <!-- <tr>
                                <th>提现金额</th>
                                <th>手续费</th>
                                <th>到账金额</th>
                            </tr>
                            <tr>
                                <td>${$vo['num']|default="0.00"}</td>
                                <td>{$vo['fee']|default="0.00"}</td>
                                <td>${$vo['mum']|default="0.00"}</td>
                            </tr> -->
                        </table>
                    </li>
                </volist>
            </empty>
            </ul>
            <script>
                $(".withdrawtop").click(function() {
                    if($(this).siblings(".bottable").is(":visible")){
                        $(this).siblings(".bottable").hide();
                        $(this).addClass('on');
                        $(this).siblings(".withdrawtable").addClass('nobotcolor');
                    }else{
                        $(this).siblings(".bottable").show();
                        $(this).removeClass('on');
                        $(this).siblings(".withdrawtable").removeClass('nobotcolor');
                    }
                });
            </script>
            <div class="pages">{$page}</div>
        </div>
        <script>
    $("#status-selectTest").change(function () {
        var status = $("#status-selectTest option:selected").val();
        window.location = '/Finance/mytx/status/' + status + '/.html';
    });


    $("#mytx_type").change(function () {
        var type = $("#mytx_type option:selected").val();
        if (type == 'tianjia') {
            window.location = '/User/bank.html';
        }
    });

    function mytxChexiao(id) {
        $.post("{:U('Finance/mytxChexiao')}", {id: id}, function (data) {
            if (data.status == 1) {
                layer.msg(data.info, {icon: 1});
                window.location.reload();
            } else {
                layer.msg(data.info, {icon: 2});
            }
        }, "json");
    }


    function SendCode() {


        $('#regBtn').attr("disabled", "disabled");
        $.post("{:U('Verify/mytx')}", {}, function (data) {
            if (data.status == 1) {
                layer.msg(data.info, {
                    icon: 1
                });
                var obj = $('#regBtn');
                var wait = 120;
                var interval = setInterval(function () {
                    obj.css('backgroundColor', '#999B9C');
                    obj.val(wait + '{:L('秒再次发送')}');
                    wait--;
                    if (wait < 0) {
                        $('#regBtn').removeAttr("disabled");
                        clearInterval(interval);
                        obj.val('{:L('获取验证码')}');
                        obj.css('backgroundColor', '#0096e0');
                    }
                    ;
                }, 1000);
            } else {
                $('#regBtn').removeAttr("disabled");
                layer.msg(data.info, {
                    icon: 2
                });
            }
        }, "json");
    }
    function Update() {
        var num = $("#num").val();
        var paypassword = $("#paypassword").val();
        var moble_verify = $("#moble_verify").val();
        var type = $('#mytx_type option:selected').val();
        // if (moble_verify == "" || moble_verify == null) {
        //  layer.tips('请输入短信验证码', '#moble_verify', {
        //      tips: 3
        //  });
        //  return false;
        // }
        if (num == "" || num == null) {
            layer.tips('{:L('请输入提现金额')}', '#num', {
                tips: 3
            });
            return false;
        }
        if (paypassword == "" || paypassword == null) {
            layer.tips('{:L('请输入交易密码')}', '#paypassword', {
                tips: 3
            });
            return false;
        }
        $.post("{:U('Finance/mytxUp')}", {
            type: type,
            num: num,
            paypassword: paypassword,
            moble_verify: moble_verify
        }, function (data) {
            if (data.status == 1) {
                layer.msg(data.info, {
                    icon: 1
                });
                window.location.reload();
            } else {
                layer.msg(data.info, {
                    icon: 2
                });
                if (data.url) {
                    window.location = data.url;
                }
            }
        }, "json");
    }
</script>
        <include file="Public:footer" />
    </div>
</body>
</html>